import { axios } from '@/utils/request'

/**
 * 查询库存表
 *
 * @author can
 * @date 2022-03-19 14:12:32
 */
export function bizStockPage (parameter) {
  return axios({
    url: '/bizStock/page',
    method: 'get',
    params: parameter
  })
}

/**
 * 库存表列表
 *
 * @author can
 * @date 2022-03-19 14:12:32
 */
export function bizStockList (parameter) {
  return axios({
    url: '/bizStock/list',
    method: 'get',
    params: parameter
  })
}

/**
 * 添加库存表
 *
 * @author can
 * @date 2022-03-19 14:12:32
 */
export function bizStockAdd (parameter) {
  return axios({
    url: '/bizStock/add',
    method: 'post',
    data: parameter
  })
}

/**
 * 编辑库存表
 *
 * @author can
 * @date 2022-03-19 14:12:32
 */
export function bizStockEdit (parameter) {
  return axios({
    url: '/bizStock/edit',
    method: 'post',
    data: parameter
  })
}

/**
 * 删除库存表
 *
 * @author can
 * @date 2022-03-19 14:12:32
 */
export function bizStockDelete (parameter) {
  return axios({
    url: '/bizStock/delete',
    method: 'post',
    data: parameter
  })
}

/**
 * 导出库存表
 *
 * @author can
 * @date 2022-03-19 14:12:32
 */
export function bizStockExport (parameter) {
  return axios({
    url: '/bizStock/export',
    method: 'get',
    params: parameter,
    responseType: 'blob'
  })
}

/**
 * 导出库存表
 *
 * @author can
 * @date 2022-03-19 14:12:32
 */
export function bizMatDown (parameter) {
  return axios({
    url: '/bizStock/get-mat-list',
    method: 'get'
  })
}

/**
 * 下单接口
 * @author can
 * @date 2022-03-19 14:12:32
 */
export function toOrder (parameter) {
  return axios({
    url: '/bizOrder/order',
    method: 'post',
    data: parameter
  })
}
